package com.example.demo;

import javax.annotation.Resource;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.stereotype.Service;

/**
 * Desc:
 *
 * @date: 27/08/2017
 * @author: Leader us
 */
@Service
public class AccountService {
    private static final Logger LOGGER = LoggerFactory.getLogger(AccountService.class);

    @Autowired
    private AccountMapper accountMapper;
   
    @Resource
    private RedisTemplate<String, ?> redisTemplate;

    public Account login(String username, String password) {
        LOGGER.info("account login, username: {}, password: {}", username, password);
        return accountMapper.getAccountByNameAndPwd(username, password);
    }
    
    
}
